/**
 * 
 */
package com.cloudcast.client.view;

import com.extjs.gxt.ui.client.widget.ContentPanel;
import com.extjs.gxt.ui.client.widget.LayoutContainer;
import com.extjs.gxt.ui.client.widget.layout.FitLayout;

/**
 * @author Samuel García Martínez <in0de>
 *
 */
public class RootView implements View {

	private LayoutContainer rootPanel; 
	
	public RootView() {
		rootPanel = buildRootPanel();
	}
	
	protected LayoutContainer buildRootPanel() {
		ContentPanel container = new ContentPanel();
		
		container.setBorders(false);
		container.setLayout(new FitLayout());
		container.setHeading("ROOT PANEL");
		container.setId("ROOTPANEL");
		container.setBorders(false);
		
		return container;
	}

	/*
	 * (non-Javadoc)
	 * @see com.cloudcast.client.view.View#asContainer()
	 */
	@Override
	public LayoutContainer asContainer() {
		return rootPanel;
	}

}
